// components/zy-popover/zy-poptrigger.js
Component({

    /**
     * 组件的属性列表
     */
    properties: {
        popovertarget: String
    },

    /**
     * 组件的初始数据
     */
    data: {

    },

    /**
     * 组件的方法列表
     */
    methods: {
        clicktrigger(e) {
            // console.log(e);
            let ownerComp = this.selectOwnerComponent();
            let targetid = this.data.popovertarget;
            this.createSelectorQuery()
            .select('.zy-popertrigger')
            .boundingClientRect((res) => {
      
                let popDom  = ownerComp.selectComponent('#' + targetid);
                // console.log(res, popDom);
                if (popDom) {
                    popDom.toggle(res)
                    // popDom.setPos(res)
                    // popDom.open()
                }
     
            }).exec()
        }
    }
})